const mongoose = require('../db/db')
const options = {
    versionKey: false,
    autoIndex: true, // auto create indexes
}

const Schema = mongoose.Schema
const accountSchema = new Schema({
        userId: {
            type: String,
            index: true,
            unique: true
        },
        password: String,
        addDate: Date,
    },
    options
)

module.exports = mongoose.model('accounts',accountSchema,'accounts')